<template>
    <div class="box" @click="handleClick">
        <el-icon class="isIconSet" ><FullScreen/></el-icon>
    </div>
</template>
<script setup>
import screenfull from 'screenfull'   //screenfull是一个全屏的插件

const handleClick = ()=>{
    if(screenfull.isEnabled){
        screenfull.toggle()      //点击打开全屏或关闭全屏
    }
}
</script>
<style scoped lang="less">
.box{
    position: relative;
    right: 60px;
    top: 8px;
}
.el-icon {
    width: 25px;
    height: 25px;
    // position: absolute;
    // right: 30px;
    // top: 8px;
    svg{
        width: 25px;
        height: 25px;
        cursor: pointer;
    }
}
</style>